package com.shareyi.joywindow.server;



import com.shareyi.joywindow.server.exception.HttpServerException;

/**
 * HttpServer Interface
 * @author david
 *
 */
public interface HttpServer {

	

	 /**
	  * initial the local listening Server
	 * @throws WoxException 
	 * @throws SimpleServerException 
	  */
	 public void init() throws  HttpServerException;

	 

	 /**
	  * start the local listening Server
	  * @return start state
	  */
	 public  boolean start() throws  HttpServerException;
	 
	 /**
	  * stop local listening Server
	  * @return stop state
	  */
	 
	 public  boolean stop() throws  HttpServerException;
	

	public int getPort();

	
	/**
	 * set bindPath directory,it's the binding parameters save file
	 * @param bindPath
	 */
	public void setBindPath(String bindPath);
	
	/**
	 * get bindPath directory
	 * @return
	 */
	public String getBindPath();


	/**
	 * allow many instance running?
	 * @return
	 */
	public  boolean isManyInstAllow();


	/**
	 * get context base path
	 * @return
	 */
	public String getBasePath();
}
